package com.jkt.rms.business.base;

import java.lang.Comparable;
import java.io.Serializable;


/**
 * This is an object that contains data related to the vendor table.
 * Do not modify this class because it will be overwritten if the configuration file
 * related to this class is modified.
 *
 * @hibernate.class
 *  table="vendor"
 */

public abstract class BaseVendor  implements Comparable, Serializable {

	public static String REF = "Vendor";
	public static String PROP_STATUS = "status";
	public static String PROP_ONSITE_PERSON_NAME = "onsitePersonName";
	public static String PROP_UPDATED_BY = "updatedBy";
	public static String PROP_POSTCODE = "postcode";
	public static String PROP_ONSITE_ADDRESS_LINE1 = "onsiteAddressLine1";
	public static String PROP_COUNTY = "county";
	public static String PROP_ONSITE_POST_CODE = "onsitePostCode";
	public static String PROP_ONSITE_ADDRESS_LINE2 = "onsiteAddressLine2";
	public static String PROP_ADDRESS_LINE1 = "addressLine1";
	public static String PROP_CONTACT_NO = "contactNo";
	public static String PROP_ONSITE_EMAIL = "onsiteEmail";
	public static String PROP_ONSITE_COUNTRY = "onsiteCountry";
	public static String PROP_ONSITE_CONTACT_NO = "onsiteContactNo";
	public static String PROP_ONSITE_BLENDED_RATE = "onsiteBlendedRate";
	public static String PROP_OFFSHORE_PERSON_NAME = "offshorePersonName";
	public static String PROP_OFFSHORE_ADDRESS_LINE2 = "offshoreAddressLine2";
	public static String PROP_OFFSHORE_TOWN = "offshoreTown";
	public static String PROP_UPDATED_DATE = "updatedDate";
	public static String PROP_ADDRESS_LINE2 = "addressLine2";
	public static String PROP_OFFSHORE_ADDRESS_LINE1 = "offshoreAddressLine1";
	public static String PROP_ONSITE_TOWN = "onsiteTown";
	public static String PROP_OFFSHORE_BLENDED_RATE = "offshoreBlendedRate";
	public static String PROP_ONSITE_COUNTY = "onsiteCounty";
	public static String PROP_EMAIL = "email";
	public static String PROP_OFFSHORE_EMAIL = "offshoreEmail";
	public static String PROP_VENDOR_NAME = "vendorName";
	public static String PROP_COMMENTS = "comments";
	public static String PROP_COUNTRY = "country";
	public static String PROP_OFFSHORE_COUNTY = "offshoreCounty";
	public static String PROP_TOWN = "town";
	public static String PROP_OFFSHORE_POST_CODE = "offshorePostCode";
	public static String PROP_OFFSHORE_CONTACT_NO = "offshoreContactNo";
	public static String PROP_ID = "id";
	public static String PROP_VENDOR_CODE = "vendorCode";
	public static String PROP_OFFSHORE_COUNTRY = "offshoreCountry";


	// constructors
	public BaseVendor () {
		initialize();
	}

	/**
	 * Constructor for primary key
	 */
	public BaseVendor (java.lang.Long id) {
		this.setId(id);
		initialize();
	}

	/**
	 * Constructor for required fields
	 */
	public BaseVendor (
		java.lang.Long id,
		java.lang.String vendorCode,
		java.lang.String vendorName,
		java.lang.String addressLine1,
		java.lang.String town,
		java.lang.String county,
		java.lang.String country,
		java.lang.String postcode,
		java.lang.String contactNo,
		java.lang.String email,
		float offshoreBlendedRate,
		float onsiteBlendedRate,
		java.lang.String updatedBy,
		java.util.Date updatedDate,
		char status,
		java.lang.String offshorePersonName,
		java.lang.String offshoreTown,
		java.lang.String offshoreCounty,
		java.lang.String offshoreCountry,
		java.lang.String offshoreContactNo,
		java.lang.String offshoreEmail,
		java.lang.String onsitePersonName,
		java.lang.String onsiteAddressLine1,
		java.lang.String onsiteTown,
		java.lang.String onsiteCounty,
		java.lang.String onsiteCountry,
		java.lang.String onsiteContactNo,
		java.lang.String onsiteEmail) {

		this.setId(id);
		this.setVendorCode(vendorCode);
		this.setVendorName(vendorName);
		this.setAddressLine1(addressLine1);
		this.setTown(town);
		this.setCounty(county);
		this.setCountry(country);
		this.setPostcode(postcode);
		this.setContactNo(contactNo);
		this.setEmail(email);
		this.setOffshoreBlendedRate(offshoreBlendedRate);
		this.setOnsiteBlendedRate(onsiteBlendedRate);
		this.setUpdatedBy(updatedBy);
		this.setUpdatedDate(updatedDate);
		this.setStatus(status);
		this.setOffshorePersonName(offshorePersonName);
		this.setOffshoreTown(offshoreTown);
		this.setOffshoreCounty(offshoreCounty);
		this.setOffshoreCountry(offshoreCountry);
		this.setOffshoreContactNo(offshoreContactNo);
		this.setOffshoreEmail(offshoreEmail);
		this.setOnsitePersonName(onsitePersonName);
		this.setOnsiteAddressLine1(onsiteAddressLine1);
		this.setOnsiteTown(onsiteTown);
		this.setOnsiteCounty(onsiteCounty);
		this.setOnsiteCountry(onsiteCountry);
		this.setOnsiteContactNo(onsiteContactNo);
		this.setOnsiteEmail(onsiteEmail);
		initialize();
	}

	protected void initialize () {}



	private int hashCode = Integer.MIN_VALUE;

	// primary key
	private java.lang.Long id;

	// fields
	private java.lang.String vendorCode;
	private java.lang.String vendorName;
	private java.lang.String addressLine1;
	private java.lang.String addressLine2;
	private java.lang.String town;
	private java.lang.String county;
	private java.lang.String country;
	private java.lang.String postcode;
	private java.lang.String contactNo;
	private java.lang.String email;
	private float offshoreBlendedRate;
	private float onsiteBlendedRate;
	private java.lang.String updatedBy;
	private java.util.Date updatedDate;
	private char status;
	private java.lang.String offshorePersonName;
	private java.lang.String offshoreAddressLine1;
	private java.lang.String offshoreAddressLine2;
	private java.lang.String offshoreTown;
	private java.lang.String offshoreCounty;
	private java.lang.String offshoreCountry;
	private java.lang.String offshorePostCode;
	private java.lang.String offshoreContactNo;
	private java.lang.String offshoreEmail;
	private java.lang.String onsitePersonName;
	private java.lang.String onsiteAddressLine1;
	private java.lang.String onsiteAddressLine2;
	private java.lang.String onsiteTown;
	private java.lang.String onsiteCounty;
	private java.lang.String onsiteCountry;
	private java.lang.String onsitePostCode;
	private java.lang.String onsiteContactNo;
	private java.lang.String onsiteEmail;
	private java.lang.String comments;



	/**
	 * Return the unique identifier of this class
     * @hibernate.id
     *  generator-class="native"
     *  column="id"
     */
	public java.lang.Long getId () {
		return id;
	}

	/**
	 * Set the unique identifier of this class
	 * @param id the new ID
	 */
	public void setId (java.lang.Long id) {
		this.id = id;
		this.hashCode = Integer.MIN_VALUE;
	}




	/**
	 * Return the value associated with the column: vendor_code
	 */
	public java.lang.String getVendorCode () {
		return vendorCode;
	}

	/**
	 * Set the value related to the column: vendor_code
	 * @param vendorCode the vendor_code value
	 */
	public void setVendorCode (java.lang.String vendorCode) {
		this.vendorCode = vendorCode;
	}



	/**
	 * Return the value associated with the column: vendor_name
	 */
	public java.lang.String getVendorName () {
		return vendorName;
	}

	/**
	 * Set the value related to the column: vendor_name
	 * @param vendorName the vendor_name value
	 */
	public void setVendorName (java.lang.String vendorName) {
		this.vendorName = vendorName;
	}



	/**
	 * Return the value associated with the column: address_Line_1
	 */
	public java.lang.String getAddressLine1 () {
		return addressLine1;
	}

	/**
	 * Set the value related to the column: address_Line_1
	 * @param addressLine1 the address_Line_1 value
	 */
	public void setAddressLine1 (java.lang.String addressLine1) {
		this.addressLine1 = addressLine1;
	}



	/**
	 * Return the value associated with the column: address_Line_2
	 */
	public java.lang.String getAddressLine2 () {
		return addressLine2;
	}

	/**
	 * Set the value related to the column: address_Line_2
	 * @param addressLine2 the address_Line_2 value
	 */
	public void setAddressLine2 (java.lang.String addressLine2) {
		this.addressLine2 = addressLine2;
	}



	/**
	 * Return the value associated with the column: town
	 */
	public java.lang.String getTown () {
		return town;
	}

	/**
	 * Set the value related to the column: town
	 * @param town the town value
	 */
	public void setTown (java.lang.String town) {
		this.town = town;
	}



	/**
	 * Return the value associated with the column: county
	 */
	public java.lang.String getCounty () {
		return county;
	}

	/**
	 * Set the value related to the column: county
	 * @param county the county value
	 */
	public void setCounty (java.lang.String county) {
		this.county = county;
	}



	/**
	 * Return the value associated with the column: country
	 */
	public java.lang.String getCountry () {
		return country;
	}

	/**
	 * Set the value related to the column: country
	 * @param country the country value
	 */
	public void setCountry (java.lang.String country) {
		this.country = country;
	}



	/**
	 * Return the value associated with the column: postcode
	 */
	public java.lang.String getPostcode () {
		return postcode;
	}

	/**
	 * Set the value related to the column: postcode
	 * @param postcode the postcode value
	 */
	public void setPostcode (java.lang.String postcode) {
		this.postcode = postcode;
	}



	/**
	 * Return the value associated with the column: contact_No
	 */
	public java.lang.String getContactNo () {
		return contactNo;
	}

	/**
	 * Set the value related to the column: contact_No
	 * @param contactNo the contact_No value
	 */
	public void setContactNo (java.lang.String contactNo) {
		this.contactNo = contactNo;
	}



	/**
	 * Return the value associated with the column: email
	 */
	public java.lang.String getEmail () {
		return email;
	}

	/**
	 * Set the value related to the column: email
	 * @param email the email value
	 */
	public void setEmail (java.lang.String email) {
		this.email = email;
	}



	/**
	 * Return the value associated with the column: offshore_blended_rate
	 */
	public float getOffshoreBlendedRate () {
		return offshoreBlendedRate;
	}

	/**
	 * Set the value related to the column: offshore_blended_rate
	 * @param offshoreBlendedRate the offshore_blended_rate value
	 */
	public void setOffshoreBlendedRate (float offshoreBlendedRate) {
		this.offshoreBlendedRate = offshoreBlendedRate;
	}



	/**
	 * Return the value associated with the column: onsite_blended_rate
	 */
	public float getOnsiteBlendedRate () {
		return onsiteBlendedRate;
	}

	/**
	 * Set the value related to the column: onsite_blended_rate
	 * @param onsiteBlendedRate the onsite_blended_rate value
	 */
	public void setOnsiteBlendedRate (float onsiteBlendedRate) {
		this.onsiteBlendedRate = onsiteBlendedRate;
	}



	/**
	 * Return the value associated with the column: updated_by
	 */
	public java.lang.String getUpdatedBy () {
		return updatedBy;
	}

	/**
	 * Set the value related to the column: updated_by
	 * @param updatedBy the updated_by value
	 */
	public void setUpdatedBy (java.lang.String updatedBy) {
		this.updatedBy = updatedBy;
	}



	/**
	 * Return the value associated with the column: updated_date
	 */
	public java.util.Date getUpdatedDate () {
		return updatedDate;
	}

	/**
	 * Set the value related to the column: updated_date
	 * @param updatedDate the updated_date value
	 */
	public void setUpdatedDate (java.util.Date updatedDate) {
		this.updatedDate = updatedDate;
	}



	/**
	 * Return the value associated with the column: status
	 */
	public char getStatus () {
		return status;
	}

	/**
	 * Set the value related to the column: status
	 * @param status the status value
	 */
	public void setStatus (char status) {
		this.status = status;
	}



	/**
	 * Return the value associated with the column: offshore_person_name
	 */
	public java.lang.String getOffshorePersonName () {
		return offshorePersonName;
	}

	/**
	 * Set the value related to the column: offshore_person_name
	 * @param offshorePersonName the offshore_person_name value
	 */
	public void setOffshorePersonName (java.lang.String offshorePersonName) {
		this.offshorePersonName = offshorePersonName;
	}



	/**
	 * Return the value associated with the column: offshore_address_line_1
	 */
	public java.lang.String getOffshoreAddressLine1 () {
		return offshoreAddressLine1;
	}

	/**
	 * Set the value related to the column: offshore_address_line_1
	 * @param offshoreAddressLine1 the offshore_address_line_1 value
	 */
	public void setOffshoreAddressLine1 (java.lang.String offshoreAddressLine1) {
		this.offshoreAddressLine1 = offshoreAddressLine1;
	}



	/**
	 * Return the value associated with the column: offshore_address_line_2
	 */
	public java.lang.String getOffshoreAddressLine2 () {
		return offshoreAddressLine2;
	}

	/**
	 * Set the value related to the column: offshore_address_line_2
	 * @param offshoreAddressLine2 the offshore_address_line_2 value
	 */
	public void setOffshoreAddressLine2 (java.lang.String offshoreAddressLine2) {
		this.offshoreAddressLine2 = offshoreAddressLine2;
	}



	/**
	 * Return the value associated with the column: offshore_town
	 */
	public java.lang.String getOffshoreTown () {
		return offshoreTown;
	}

	/**
	 * Set the value related to the column: offshore_town
	 * @param offshoreTown the offshore_town value
	 */
	public void setOffshoreTown (java.lang.String offshoreTown) {
		this.offshoreTown = offshoreTown;
	}



	/**
	 * Return the value associated with the column: offshore_county
	 */
	public java.lang.String getOffshoreCounty () {
		return offshoreCounty;
	}

	/**
	 * Set the value related to the column: offshore_county
	 * @param offshoreCounty the offshore_county value
	 */
	public void setOffshoreCounty (java.lang.String offshoreCounty) {
		this.offshoreCounty = offshoreCounty;
	}



	/**
	 * Return the value associated with the column: offshore_country
	 */
	public java.lang.String getOffshoreCountry () {
		return offshoreCountry;
	}

	/**
	 * Set the value related to the column: offshore_country
	 * @param offshoreCountry the offshore_country value
	 */
	public void setOffshoreCountry (java.lang.String offshoreCountry) {
		this.offshoreCountry = offshoreCountry;
	}



	/**
	 * Return the value associated with the column: offshore_postcode
	 */
	public java.lang.String getOffshorePostCode () {
		return offshorePostCode;
	}

	/**
	 * Set the value related to the column: offshore_postcode
	 * @param offshorePostCode the offshore_postcode value
	 */
	public void setOffshorePostCode (java.lang.String offshorePostCode) {
		this.offshorePostCode = offshorePostCode;
	}



	/**
	 * Return the value associated with the column: offshore_contact_no
	 */
	public java.lang.String getOffshoreContactNo () {
		return offshoreContactNo;
	}

	/**
	 * Set the value related to the column: offshore_contact_no
	 * @param offshoreContactNo the offshore_contact_no value
	 */
	public void setOffshoreContactNo (java.lang.String offshoreContactNo) {
		this.offshoreContactNo = offshoreContactNo;
	}



	/**
	 * Return the value associated with the column: offshore_email
	 */
	public java.lang.String getOffshoreEmail () {
		return offshoreEmail;
	}

	/**
	 * Set the value related to the column: offshore_email
	 * @param offshoreEmail the offshore_email value
	 */
	public void setOffshoreEmail (java.lang.String offshoreEmail) {
		this.offshoreEmail = offshoreEmail;
	}



	/**
	 * Return the value associated with the column: onsite_person_name
	 */
	public java.lang.String getOnsitePersonName () {
		return onsitePersonName;
	}

	/**
	 * Set the value related to the column: onsite_person_name
	 * @param onsitePersonName the onsite_person_name value
	 */
	public void setOnsitePersonName (java.lang.String onsitePersonName) {
		this.onsitePersonName = onsitePersonName;
	}



	/**
	 * Return the value associated with the column: onsite_address_line_1
	 */
	public java.lang.String getOnsiteAddressLine1 () {
		return onsiteAddressLine1;
	}

	/**
	 * Set the value related to the column: onsite_address_line_1
	 * @param onsiteAddressLine1 the onsite_address_line_1 value
	 */
	public void setOnsiteAddressLine1 (java.lang.String onsiteAddressLine1) {
		this.onsiteAddressLine1 = onsiteAddressLine1;
	}



	/**
	 * Return the value associated with the column: onsite_address_line_2
	 */
	public java.lang.String getOnsiteAddressLine2 () {
		return onsiteAddressLine2;
	}

	/**
	 * Set the value related to the column: onsite_address_line_2
	 * @param onsiteAddressLine2 the onsite_address_line_2 value
	 */
	public void setOnsiteAddressLine2 (java.lang.String onsiteAddressLine2) {
		this.onsiteAddressLine2 = onsiteAddressLine2;
	}



	/**
	 * Return the value associated with the column: onsite_town
	 */
	public java.lang.String getOnsiteTown () {
		return onsiteTown;
	}

	/**
	 * Set the value related to the column: onsite_town
	 * @param onsiteTown the onsite_town value
	 */
	public void setOnsiteTown (java.lang.String onsiteTown) {
		this.onsiteTown = onsiteTown;
	}



	/**
	 * Return the value associated with the column: onsite_county
	 */
	public java.lang.String getOnsiteCounty () {
		return onsiteCounty;
	}

	/**
	 * Set the value related to the column: onsite_county
	 * @param onsiteCounty the onsite_county value
	 */
	public void setOnsiteCounty (java.lang.String onsiteCounty) {
		this.onsiteCounty = onsiteCounty;
	}



	/**
	 * Return the value associated with the column: onsite_country
	 */
	public java.lang.String getOnsiteCountry () {
		return onsiteCountry;
	}

	/**
	 * Set the value related to the column: onsite_country
	 * @param onsiteCountry the onsite_country value
	 */
	public void setOnsiteCountry (java.lang.String onsiteCountry) {
		this.onsiteCountry = onsiteCountry;
	}



	/**
	 * Return the value associated with the column: onsite_postcode
	 */
	public java.lang.String getOnsitePostCode () {
		return onsitePostCode;
	}

	/**
	 * Set the value related to the column: onsite_postcode
	 * @param onsitePostCode the onsite_postcode value
	 */
	public void setOnsitePostCode (java.lang.String onsitePostCode) {
		this.onsitePostCode = onsitePostCode;
	}



	/**
	 * Return the value associated with the column: onsite_contact_no
	 */
	public java.lang.String getOnsiteContactNo () {
		return onsiteContactNo;
	}

	/**
	 * Set the value related to the column: onsite_contact_no
	 * @param onsiteContactNo the onsite_contact_no value
	 */
	public void setOnsiteContactNo (java.lang.String onsiteContactNo) {
		this.onsiteContactNo = onsiteContactNo;
	}



	/**
	 * Return the value associated with the column: onsite_email
	 */
	public java.lang.String getOnsiteEmail () {
		return onsiteEmail;
	}

	/**
	 * Set the value related to the column: onsite_email
	 * @param onsiteEmail the onsite_email value
	 */
	public void setOnsiteEmail (java.lang.String onsiteEmail) {
		this.onsiteEmail = onsiteEmail;
	}



	/**
	 * Return the value associated with the column: comments
	 */
	public java.lang.String getComments () {
		return comments;
	}

	/**
	 * Set the value related to the column: comments
	 * @param comments the comments value
	 */
	public void setComments (java.lang.String comments) {
		this.comments = comments;
	}





	public boolean equals (Object obj) {
		if (null == obj) return false;
		if (!(obj instanceof com.jkt.rms.business.Vendor)) return false;
		else {
			com.jkt.rms.business.Vendor vendor = (com.jkt.rms.business.Vendor) obj;
			if (null == this.getId() || null == vendor.getId()) return false;
			else return (this.getId().equals(vendor.getId()));
		}
	}

	public int hashCode () {
		if (Integer.MIN_VALUE == this.hashCode) {
			if (null == this.getId()) return super.hashCode();
			else {
				String hashStr = this.getClass().getName() + ":" + this.getId().hashCode();
				this.hashCode = hashStr.hashCode();
			}
		}
		return this.hashCode;
	}

	public int compareTo (Object obj) {
		if (obj.hashCode() > hashCode()) return 1;
		else if (obj.hashCode() < hashCode()) return -1;
		else return 0;
	}

	public String toString () {
		return super.toString();
	}


}